//import java.util;


/**
 * Created with IntelliJ IDEA.
 * Description:
 * User: GaoBo
 * Date: 2021-05-21
 * Time: 14:14
 */
class Person {
    public String name;
    public int age;

    static {
        System.out.println("Person::static{}");//1
    }

    {
        System.out.println("Person::{   }");//2
    }

    public Person(String name, int age) {
        this.name = name;
        this.age = age;
        System.out.println("Person(String,int)");//3
    }
}
//alt+回车
class Student extends Person{

    //Person person=new Person();

    static {
        System.out.println("Student::static{}");//4
    }

    {
        System.out.println("Student::{   }");//5
    }

    public Student(String name, int age) {
        super(name, age);
        System.out.println("Student(String,int)");//6
    }
}

class B {
    public int Func() {
        System.out.print("B");
        return 0;
    }
}
class D extends B {
    @Override
    public int Func() {
        System.out.print("D");
        return 0;
    }
}

class Base{
    public Base() {

    }
    public Base(String s){
        System.out.print("B");
    }
}

class Derived  extends Base {

    public Derived (String s) {
        //super();
        System.out.print("D");
    }

    public static void main( String[] args ) {

    }

}
 interface IA {

}
public class TestDemo {

    public static void main(String[] args) {

    }

    public static void main2(String[] args) {
        Student student = new Student("bit",19);
    }
    public static void main1(String[] args) {
        Person person = new Person("bit",19);
        System.out.println("==============");
        Person person2 = new Person("bit2",192);
    }
}
